<!DOCTYPE HTML>
<html>
<head>
<title>/JumpToRecordFieldWhenVarIsOfRecordTypeFromLamBinding.dhall</title>
<link rel="stylesheet" type="text/css" href="index.css">
<link rel="stylesheet" type="text/css" href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600;700&amp;family=Lato:ital,wght@0,400;0,700;1,400&amp;display=swap">
<script src="index.js">
</script>
<meta charset="UTF-8">
</head>
<body>
<div class="nav-bar">
<img class="dhall-icon" alt="Dhall logo." src="dhall-icon.svg">
<p class="package-title">test-package</p>
<div class="nav-bar-content-divider">
</div>
<a id="switch-light-dark-mode" class="nav-option">Switch Light/Dark Mode</a>
</div>
<div class="main-container">
<h2 class="doc-title">
<span class="crumb-divider">/</span>
<a href="index.html">test-package</a>
<span class="crumb-divider">/</span>
<span class="title-crumb" href="index.html">JumpToRecordFieldWhenVarIsOfRecordTypeFromLamBinding.dhall</span>
</h2>
<a class="copy-to-clipboard" data-path="/JumpToRecordFieldWhenVarIsOfRecordTypeFromLamBinding.dhall">
<i>
<small>Copy path to clipboard</small>
</i>
</a>
<br>
<div class="doc-contents">
<p>On this example, <code>dhall-docs</code> will detect that the argument <code>a</code> of the only
function in this file is of record type. Therefore, any interactions on selector
expressions over the <code>a</code> variable will interact with the fields on the record-type.</p>
<p>Note that the treatment for <code>Lam</code> variables is different from <code>Let</code> bindings:
the annotation doesn&#39;t affect on the later case. This can be seen in the
<a href="./JumpToRecordFieldWhenLetAnnotationPresentShouldIgnoreAnnotation.dhall">test case for let bindings</a>
</p>
</div>
<h3>Source</h3>
<div class="source-code">
<pre>{-|<br>On this example, `dhall-docs` will detect that the argument `a` of the only<br>function in this file is of record type. Therefore, any interactions on selector<br>expressions over the `a` variable will interact with the fields on the record-type.<br>
<br>Note that the treatment for `Lam` variables is different from `Let` bindings:<br>the annotation doesn&#39;t affect on the later case. This can be seen in the<br>[test case for let bindings](./JumpToRecordFieldWhenLetAnnotationPresentShouldIgnoreAnnotation.dhall)<br>-}<br>
<br>λ(<span id="var11-3" class="name-decl" data-name="var11-3">b</span> : Type) →<br>λ(<span id="var12-3" class="name-decl" data-name="var12-3">c</span> : Type) →<br>λ(<span id="var13-3" class="name-decl" data-name="var13-3">a</span> : { <span id="var13-9" class="name-decl" data-name="var13-9">list</span> : List <a href="#var11-3" class="name-use" data-name="var11-3">b</a>, <span id="var13-24" class="name-decl" data-name="var13-24">cons</span> : <a href="#var11-3" class="name-use" data-name="var11-3">b</a> → <a href="#var12-3" class="name-use" data-name="var12-3">c</a> → <a href="#var12-3" class="name-use" data-name="var12-3">c</a>, <span id="var13-42" class="name-decl" data-name="var13-42">nil</span> : <a href="#var12-3" class="name-use" data-name="var12-3">c</a> }) →<br>  List/fold <a href="#var11-3" class="name-use" data-name="var11-3">b</a> <a href="#var13-3" class="name-use" data-name="var13-3">a</a>.<a href="#var13-9" class="name-use" data-name="var13-9">list</a> <a href="#var12-3" class="name-use" data-name="var12-3">c</a> <a href="#var13-3" class="name-use" data-name="var13-3">a</a>.<a href="#var13-24" class="name-use" data-name="var13-24">cons</a> <a href="#var13-3" class="name-use" data-name="var13-3">a</a>.<a href="#var13-42" class="name-use" data-name="var13-42">nil</a>
<br>
</pre>
</div>
</div>
</body>
</html>